package com.hdax.dm.controller;

import com.hdax.dm.dto.CommonResponse;
import com.hdax.dm.dto.DtoUtil;
import com.hdax.dm.service.ItemCService;
import com.hdax.dm.service.ItemDescService;
import com.hdax.dm.service.ItemTypeService;
import com.hdax.dm.vo.FloorVo;
import com.hdax.dm.vo.ItemDescVo;
import com.hdax.dm.vo.LineNavVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Primary;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
public class ItemTypeController {

    @Autowired
    private ItemTypeService itemTypeService;

    //查询全部商品分类顶部
    @PostMapping(path = "/lineNav")
    public CommonResponse<List<LineNavVo>> itemDesc(){
        return DtoUtil.returnSuccess("",itemTypeService.lineNav());
    }

    //查询商品楼层
    @PostMapping(path = "/floor")
    public CommonResponse<List<FloorVo>> floor(){
        return DtoUtil.returnSuccess("",itemTypeService.floor());
    }

}
